package com.g2.admin.model.to;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModelProperty;
import lombok.Builder;
import lombok.Data;

import java.util.Date;
import java.util.List;

@Data
@Builder
public class AuthTreeTo {

    private boolean checked;
    @ApiModelProperty(value = "权限编码")
    private String code;
    @ApiModelProperty(value = "链接地址，只有栏目和菜单才有会有此字段。考虑兼容到url、id触发、调用方法触发")
    private String href;
    @ApiModelProperty(value = "菜单ICON，只有栏目和菜单才有会有此字段。考虑兼容三种情况：1、url；2、class引用；3、icon的base64编码。")
    private String icon;
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    @ApiModelProperty(value = "权限名称")
    private String name;
    @ApiModelProperty(value = "所属父权限编码")
    private String parentCode;
    @ApiModelProperty(value = "所属父权限名称")
    private String parentName;
    @ApiModelProperty(value = "备注说明")
    private String remark;
    @ApiModelProperty(value = "排序：数字越大越在前面")
    private Integer sort;
    @ApiModelProperty(value = "所属系统编码")
    private String systemCode;
    @ApiModelProperty(value = "所属系统名称")
    private String systemName;
    @ApiModelProperty(value = "类型：1、栏目；2、菜单；3、按钮；4、功能。第4类型属于后台校验的权限")
    private Integer type;
    private List<AuthTreeTo> children;
}
